<template>
  <div class="aside" >
    <el-menu
      default-active="2"
      class="el-menu-vertical-demo"
      @open="handleOpen"
      @close="handleClose"
      background-color="#F3CDAA"
      text-color="#000"
      active-text-color="#E0803C"
      router="true">
      <el-submenu >
        <template slot="title" >
          <span>
            预防保健
          </span>
        </template>
          <el-menu-item index="/test/page2">自我保健</el-menu-item>
        <el-menu-item index="/test/page2">医疗保险</el-menu-item>
      </el-submenu>
      <el-submenu index="2">
      <template slot="title" style="background-color:#E4BA92">
          <span>
            信息管理
          </span>
      </template>
      <el-menu-item index="/test/page1">号源管理</el-menu-item>
      </el-submenu>
    </el-menu>
  </div>
</template>

<script>
    export default {
        name: "Aside",
        methods: {
        handleOpen(key, keyPath) {
          console.log(key, keyPath);
        },
        handleClose(key, keyPath) {
          console.log(key, keyPath);
        }
      }
    }
</script>

<style scoped>

</style>
